import request from '@/utils/request'



export function dynamicStateList(data) { //部门月报-列表
  return request({
    url: '/project-quality/api/product/daily/page',
    method: 'post',
    data
  })
}


export function dynamicStateAdd(data) { //部门月报-新增
  return request({
    url: '/project-quality/api/product/daily/add',
    method: 'post',
    data
  })
}


export function dynamicStateEdit(data) { //部门月报-编辑
  return request({
    url: '/project-quality/api/product/daily/edit',
    method: 'post',
    data
  })
}


export function dynamicStateDetailsDate(data) { //根据设施和日期查询相关默认数据
  return request({
    url: '/project-quality/api/product/daily/report',
    method: 'post',
    data
  })
}




export function dynamicStateDelete(id) { //部门月报-删除
  return request({
    url: '/project-quality/api/product/daily/del/' + id,
    method: 'get',
  })
}


export function dynamicStateDetails(id) { //部门月报-详情
  return request({
    url: '/project-quality/api/product/daily/' + id,
    method: 'get',
  })
}
export function dynamicStatehExport(data) { //部门月报-导出
  return request({
    url: '/project-quality/api/deptMonthReportList/export',
    responseType: 'arraybuffer',
    method: 'post',
    data
  })
}


export function dynamicStateExport(data) { //下载导入的Excel的模板
    return request({
        url: '/project-quality/api/product/export',
        responseType: 'arraybuffer',
        method: 'POST',
        data
    })
}

export function dynamicStateExport2(data) { //生产装备动态信息表
    return request({
        url: '/project-quality/api/product/daily/export',
        responseType: 'arraybuffer',
        method: 'POST',
        data
    })
}


export function dynamicStatehTree(data) { //设施/现场树结构
  return request({
    url: '/sys-center/api/system/roles/treeDept',
    method: 'post',
    data
  })
}
export function dynamicStateAddDetails(data) { //获取最新的数据
  return request({
    url: '/project-quality/api/product/daily/new',
    method: 'post',
    data
  })
}


